package com.genius.smsweb.teachermanage;

import com.genius.smsbase.Controller.GenericController;
import com.genius.smsdao.teachermanage.domain.Teacher;
import com.genius.smsservice.teachermanage.service.TeacherManager;
import io.swagger.annotations.Api;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@Api(tags = "教师管理-教师", description = "TeacherController")
@RestController             //  定义controller层
@RequestMapping("teacher") //处理请求Teacher地址映射的注解
public class TeacherController extends GenericController<Teacher,Long, TeacherManager> {

    TeacherManager teacherManager;  //声明teacher服务类的对象

    @Autowired  //对类成员变量、方法及构造函数进行标注
    public void setTeacherManager(TeacherManager teacherManager){   //生成服务类的对象
        this.teacherManager = teacherManager;
        this.manager = this.teacherManager;
    }

}
